#ifndef __DEVICE_H__
#define __DEVICE_H__

#include <stdint.h>
#include <stdbool.h>
#include <stddef.h>
#include <string.h>

#define Cw_Count 3

typedef struct {
    uint8_t cwNumber;
    uint8_t workFreqComMode[Cw_Count];

    uint8_t upAttenuation[Cw_Count];
    uint8_t dnAttenuation[Cw_Count];

    uint8_t upCwMaxGain[Cw_Count];
    uint8_t dnCwMaxGain[Cw_Count];

    int8_t upOutPower[Cw_Count];
    int8_t dnOutPower[Cw_Count];

    uint8_t up_lack_power_alarm[Cw_Count];
    uint8_t dn_lack_power_alarm[Cw_Count];
    uint8_t up_over_power_alarm[Cw_Count];
    uint8_t dn_over_power_alarm[Cw_Count];

    int8_t upCwRatedPower[Cw_Count];
    int8_t dnCwRatedPower[Cw_Count];
} device_info_t;

char *get_system_name_by_code(uint8_t code);
void inid_device_info(void);
int8_t filter_update(uint8_t ch, int8_t raw);

#endif  // __DEVICE_H__
